export const imgerror = {
  // 当被绑定的元素插入到 DOM 中时……
  inserted: function(el, { value }) {
    // 聚焦元素
    console.log({ el, value })
    el.addEventListener('error', () => {
      // console.log('图片裂了')
      el.src = value
    })
  }
}
export const color = {
  inserted(el, binding) {
    console.log(el, binding)
    el.style.color = binding.value
  }
}
